package com.iraeta.service.iraorder.impl;

import com.iraeta.dao.iraorder.IraorderwuliustepDao;
import com.iraeta.entity.IraOrderWuLiuStep;
import com.iraeta.service.iraorder.IraOrderWuLiuStepService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

@Service
public class IraOrderWuLiuStepServiceImpl implements IraOrderWuLiuStepService {
    @Resource
    IraorderwuliustepDao iraorderwuliustepDao;

    @Override
    public void addIraOrderWuLiuStep(IraOrderWuLiuStep iraOrderWuLiuStep) {
        iraorderwuliustepDao.insert(iraOrderWuLiuStep);
    }

    @Override
    public void updateIraOrderWuLiuStep(IraOrderWuLiuStep iraOrderWuLiuStep) {
        iraorderwuliustepDao.updateByPrimaryKey(iraOrderWuLiuStep);
    }

    @Override
    public void deleteIraOrderWuLiuStep(Integer id) {
        iraorderwuliustepDao.deleteByPrimaryKey(id);
    }

    @Override
    public IraOrderWuLiuStep getIraOrderWuLiuStep(Integer id) {
        return iraorderwuliustepDao.selectByPrimaryKey(id);
    }

    @Override
    public List<IraOrderWuLiuStep> listIraOrderWuLiuStep(Integer orderId) {
        return iraorderwuliustepDao.selectByOrderId(orderId);
    }
}
